CPU
Von Neumann model
- In the mid-1940s, John Von Neumann developed the concept of the stored program computer.
- It has been the basis of computer architecture for many years.
- The main, previously unavailable, features of the Von Neumann architecture were
- a central processing unit (CPU or processor)
- a processor able to access the memory directly
- computer memories that could store programs as well as data
- stored programs made up of instructions that could be executed in sequential order.
- The main components of the processor are the arithmetic logic unit (ALU), the control unit (CU), the system clock and the immediate access store (IAS).
- The ALU allows the required arithmetic or logic operations to be carried out while a program is being run.
- The accumulator (ACC) is a temporary register used when carrying out ALU calculations.
- The CU reads an instruction from memory (the address of the location where the instruction can be found is stored in the program counter (PC)).
- A system clock is used to produce timing signals on the control bus to ensure this vital synchronisation takes place – without the clock the computer would simply crash.
- The IAS holds all the data and programs that the processor (CPU) needs to access. The CPU takes data and programs held in backing store and puts them into the IAS temporarily. The IAS is another name for primary (RAM) memory.
CPU
The main part of Von Neumann model?
CPU
The accumulator is a temporary register used when carrying out ALU calculations
CPU
The allows the required arithmetic or logic operations to be carried out while a program is being run
CPU
The holds all the data and programs that the processor (CPU) needs to access.
Register
- One of the most fundamental components of the Von Neumann system is the register.
- Registers can be general purpose or special purpose.
- General purpose registers hold data that is frequently used by the CPU or can be used by the programmer when addressing the CPU directly.
- Special purpose registers have a specific function within the CPU and hold the program state.
Register | Abbreviation | Function/purpose of register |
---|---|---|
current instruction register | CIR | stores the current instruction being decoded and executed |
index register | IX | used when carrying out index addressing operations (assembly code) |
memory address register | MAR | stores the address of the memory location currently being read from or written to |
memory data register | MDR | stores data which has just been read from memory or data which is about to be written to memory (sometimes referred to as MBR) |
program counter | PC | stores the address where the next instruction to be read can be found |
status register | SR | contain bits which can be set or cleared depending on the operation (for example, to indicate overflow in a calculation) |
CPU
The stores the current instruction being decoded and executed.
CPU
The stores the address where the next instruction to be read can be found
CPU
The contains bits which can be set or cleared depending on the operation
CPU
The used when carrying out index addressing operations (assembly code)
System buses
- System buses are used in computers as a parallel transmission component; each wire in the bus transmits one bit of data.
- There are three common buses used in the Von Neumann architecture known as address bus, data bus and control bus.
Type of bus | Description of bus | Direction |
---|---|---|
Address bus | Carries signals relating to addresses | Unidirectional |
Data bus | Carries data | Bi-directional |
Control bus | Carries signals relating to the control | Bi-directional |
CPU
The carries signals relating to addresses
How to improve computer performance
- increasing bus width increases the performance and speed of a computer system
- increasing clock speed usually increases the speed of a computer
- use of multi-core CPUs
- use of cache memories can also speed up a processor’s performance.
CPU
How to improve computer performance?
Computer ports
- Input and output devices are connected to a computer via ports.
- The Universal Serial Bus (USB) is an asynchronous serial data transmission method. It has quickly become the standard method for transferring data between a computer and a number of devices.
- High-definition multimedia interface (HDMI) ports allow output (both audio and visual) from a computer to an HDMI-enabled device. It uses high-bandwidth digital copy protection (HDCP). HDCP uses a type of authentication protocol.
- Video Graphics Array (VGA) was introduced at the end of the 1980s. VGA supports 640 × 480 pixel resolution on a television or monitor screen. It can also handle a refresh rate of up to 60Hz (60 frames a second) provided there are only 16 different colours being used.
Universal Serial Bus (USB)
HDMI & VGA
USB
Which is the advantage of USB?
HDMI
Which is the advantage of HDMI?
VGA
Which is the advantage of VGA?
Fetch-execute cycle
- To execute a set of instructions, the processor first fetches data and instructions from memory and stores them in suitable registers.
- Once this is done, each instruction needs to be decoded before being executed.
Fetch
- The next instruction is fetched from the memory address currently stored in the program counter (PC) and is then stored in the current instruction register (CIR).
- The PC is then incremented (increased by 1) so that the next instruction can be processed.
- This is decoded so that each instruction can be interpreted in the next part of the cycle.
Execute
- The processor passes the decoded instruction as a set of control signals to the appropriate components within the computer system.
- This allows each instruction to be carried out in its logical sequence.
Register Transfer Notation (RTN)
When registers are involved, it is possible to describe what is happening by using Register Transfer Notation (RTN).
In its simplest form:
MAR ← [PC] contents of PC copied into MAR
[PC] ← [PC] + 1 PC is incremented by 1
MDR ← [[MAR]] data stored at address shown in MAR is copied into MDR
CIR ← [MDR] contents of MDR copied into CIR
Fetch
Register Transfer Notation (RTN) for fetch-execute cycle:
- ← [] contents of PC copied into MAR
- [] ← [] + 1 PC is incremented by 1
- ← [[]] data stored at address shown in MAR is copied into MDR
- ← [] contents of MDR copied into CIR
Interrupts
An interrupt is a signal sent from a device or from software to the processor.
This will cause the processor to temporarily stop what it is doing and service the interrupt.
Interrupts can be caused by, for example
- a timing signal
- input/output processes
- a hardware
- a software error
Once the interrupt signal is received, the processor either carries on with what it was doing or stops to service the device/program that generated the interrupt.
The computer needs to identify the interrupt type and also establish the level of interrupt priority.
Use of interrupts in the fetch-execute cycle
Interrupt
Interrupts can be caused by, for example: